---
title: MindsDB and MongoDB Compass
sidebarTitle: MongoDB Compass
---

<iframe
  className="w-full h-96"
  width="613"
  height="286"
  src="https://www.youtube.com/embed/qVmMdCofk30"
  title="Connect using Mongo Compass"
  frameBorder="0"
  allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"
  allowFullScreen
></iframe>

MongoDB Compass is a graphical user interface (GUI) for MongoDB. It provides detailed schema visualizations, real-time performance metrics, sophisticated querying abilities, and more. You can download MongoDB Compass [here](https://www.mongodb.com/try/download/compass).

## Overview

Here is an overview of the connection between MindsDB and MongoDB Compass:

<p align="center">
  <img src="/assets/connect_mongo_compass.png" />
</p>

Let's go through the steps presented above:

1. We connect MongoDB Compass to MindsDB. It is discussed in the following content.

2. We connect MindsDB to a database. You can use the [`CREATE DATABASE`](/sql/create/databases) statement and run it from MindsDB, passing all required database connection details.

3. Having completed steps 1 and 2, you can access the connected database from MongoDB Compass via MindsDB.

## How to Connect

Here is how to connect MongoDB Compass to MindsDB using either MindsDB Cloud or local installation.

<Info>
Please add the [MindsDB Cloud Public IPs](/faqs/whitelist-ips) to the access list of your Mongo database.
</Info>

<Tabs>

  <Tab title= "Local MindsDB">
  
    First, create a new connection in MongoDB Compass by clicking the `New Connection` button in the left navigation panel.

    The host value is `127.0.0.1` and the port value is `47336`. Input it in the `Host` field, as below.

    <p align="center">
      <img src="/assets/connect_mongo_compass_3.png" />
    </p>

  </Tab>

  <Tab title="MindsDB Cloud">

    First, create a new connection in MongoDB Compass by clicking the `New Connection` button in the left navigation panel.

    The host value is `cloud.mindsdb.com` and the port value is `27017`. Input it in the `Host` field, as below.

    <p align="center">
      <img src="/assets/connect_mongo_compass_1.png" />
    </p>

    Next, go to the `Authentication` tab and input the username and password to your MindsDB Cloud account, as below.

    <p align="center">
      <img src="/assets/connect_mongo_compass_2.png" />
    </p>

  </Tab>

  <Tab title="MindsDB Pro">

    First, create a new connection in MongoDB Compass by clicking the `New Connection` button in the left navigation panel.

    It is similar to connecting MindsDB Cloud. Here, the host value is the IP of your dedicated instance and the port value is 3306.

    Here is what you need to connect:
    
    ```
    Host: <dedicated instance ip>:3306
    Username: <your MindsDB Cloud username>
    Password: <your MindsDB Cloud password>
    ```
  </Tab>
</Tabs>

## What's Next?

Now that you are all set, we recommend you check out our **Tutorials** section, where you'll find various examples of regression, classification, and time series predictions with MindsDB.

To learn more about MindsDB itself, follow the guide on [MindsDB collection structure](/mongo/collection-structure/). Also, don't miss out on the remaining pages from the **Mongo API** section, as these explain common MQL syntax with examples.

Have fun!

<Tip>
**From Our Community**

Check out the video guides created by our community:

- Video guide on [How to connect Mongo Compass to MindsDB](https://youtube.com/video/ziRxRHvuSJc)
  by [HellFire](https://github.com/Artemis6969)

- Video guide on [Integrating your MindsDB instance into MongoDB](https://www.youtube.com/watch?v=xwUGBbNkyks)
  by [Syed Zubeen](https://github.com/syedzubeen)
</Tip>
